1. Field of the Invention
The present invention relates to a cylinder identification apparatus for an internal combustion engine that is adapted to identify a cylinder in accordance with a signal output from a crank angle sensor and, more particularly, to a cylinder identification apparatus capable of determining whether a noise is on a signal output from the crank angle sensor.
2. Description of the Related Art
A signal in synchronization with the revolution of an engine is used to control the ignition timing, fuel injection, etc. of an internal combustion engine. A generator producing the signal usually detects the revolution of a camshaft or a crankshaft of the engine. An example of a crank angle sensor is shown in FIG. 4 and FIG. 5. A crank angle sensor, generally designated at reference numeral 8 in these figures, includes a rotary shaft 1, which rotates in synchronization with an engine (not shown), a rotary disc 2 which is mounted on the rotary shaft 1 and provided with a plurality of windows 3 at locations each corresponding to a desired detection angle or angular position of a corresponding cylinder, a light emitting diode 4f or emitting a beam of light, a photodiode 5 receiving the light emitted from the light emitting diode 4, an amplifier circuit 6 connected to the photodiode 5 for amplifying an output signal of the photodiode 5, and an output transistor 7 which is connected to the amplifier circuit 6 and has an open collector. A window 3' for identifying a particular cylinder is provided in the rotary disc 2 so that it is disposed in an asymmetric relation with respect to the windows 3 which identify other (non-particular) cylinders.
Thus, the crank angle sensor 8 outputs a signal illustrated in FIG. 6. The signal has a falling edge for a particular cylinder, namely, cylinder #1, which is offset 10 degrees toward a retarding side (ATDC 5 degrees or 5 degrees after top dead center) from those for the other cylinders, namely, cylinder #2, cylinder #3, and cylinder #4. The signal also has rising edges for all the cylinders at BTDC 75 degrees or 75 degrees before top dead center.
Referring now to FIG. 7 and FIG. 8, the way how to identify a particular cylinder will be described. As shown in FIG. 7, the output signal of the crank angle sensor 8 is supplied to a microcomputer 10 via an interface circuit 9. The microcomputer 10 identifies the particular cylinder according to a flowchart shown in FIG. 8. First, in step S1, a high-level output period t and its cycle (i.e., periods between successive rising edges) T of a signal waveform of the crank angle sensor signal shown in FIG. 6 are calculated, and the flow then proceeds to step S2 wherein a ratio t/T is calculated. Subsequently, in step S3, a mean threshold value .alpha..sub.n that gives t.sub.1 /T&gt;.alpha.&gt;t.sub.0 /T is provided, and .alpha..sub.n is determined according to the following operational expression: EQU .alpha..sub.n =(1-k).alpha..sub.n-1 +k(t/T).sub.n
where k=constant
The value of .alpha..sub.n calculated in step S3 is compared with the ratio t/T (step S4), and if it is found that t/T-.alpha..sub.n &gt;0, then it is decided that the cylinder is the particular cylinder and an identification flag is set (step S5). If it is found in step S4 that t/T-.alpha..sub.n &lt;0, then it is decided that the cylinder is a different cylinder.
FIG. 9 schematically illustrates an example of the crank angle sensor according to another prior art. A crank angle sensor 18 in the figure comprises a rotary magnetic member 18a which is mounted on a camshaft or the like that rotates in synchronization with at crankshaft of an engine, and the outer periphery of which is provided with teeth formed by a plurality of projections and recessions for detecting a crank angle; and a magnetic detector 18b which is disposed near the rotary magnetic member 18a such that it is opposed to the projections of the rotary magnetic member 18a to detect a change in the magnetic force caused by a change in the distance relative to the projections and recessions so as to detect positions of the projections and recessions, i.e., crank angles. The output signals of the magnetic detector 18b are supplied to the microcomputer 10.
FIG. 10A shows the output signals of the crank angle sensor 18 of FIG. 9 and the count values on a cylinder identification counter incorporated in the microcomputer 10; FIG. 10B shows the timing of interrupt processing, such as the processing for fuel injection and ignition control, controlled by a timer incorporated in the microcomputer 10; and FIG. 10C shows interrupt timing at which interrupts are made in synchronization with crank angle signals.
As is obvious from FIG. 9 and FIG. 10A, the teeth or projections of the teeth of the rotary magnetic member 18a are provided almost at every 10.degree. of crank angle (10.degree. CA), some being provided at 30.degree. of crank angle (30.degree. CA ). For example, in the case of a four-cylinder internal combustion engine in which the first and the fourth cylinders, and the second and the third cylinders are ignited at the same time, the teeth are provided at the intervals of 30.degree. of crank angle (30.degree. CA) between B35 (35.degree. CA before top dead center cylinders and an immediately preceding signal, between B5 (5.degree. CA before top dead center) of the second and the third cylinders and an immediately preceding signal, and between the immediately preceding signal and a signal preceding the immediately preceding signal.
The way for identifying cylinders using the signals is almost the same as the conventional art example shown in FIG. 4 through FIG. 8.
As shown in FIG. 10B, the microcomputer 10 controls the internal combustion engine so as to start operational processing such as ignition or fuel injection at a predetermined crank angle (e.g., B75 or B35).
The cylinder identification counter incorporated in the microcomputer 10 is set so as to increment its count in synchronization with the output signals or angle signals of the crank angle sensor 18. For instance, as shown in FIG. 10C, the cylinder identification counter increments its count for each 10.degree. CA of crank angle, and it is reset when the crankshaft has rotated twice.
At a count value 33 on the cylinder identification counter that corresponds to the output signal (particular angle signal B35) of the crank angle sensor 18 indicative of the crank angle B35.degree. CA in a normal condition (no noise), the microcomputer 10 calculates the ratio of a time interval between count values 29 and 30 corresponding to an interval or angle between the crank angles B75.degree. CA and B65.degree. CA to another time interval between the count values 30 and 33 corresponding to an interval or angle between the crank angles B65.degree. CA and B35.degree. CA. If the calculated ratio is approximately 1:3, that is, within a predetermined error range, then the microcomputer 10 decides that the output signal of the crank angle sensor 18 is normal, i.e., free of noise (see FIG. 10A); or if it is outside the predetermined error range, then the microcomputer 10 decides that the output signal is abnormal or includes a noise. More specifically, as illustrated in FIG. 11A, if a noise enters an output signal of the crank angle sensor 18, the cylinder identification counter is incremented by the noise, so that the foregoing ratio fails to fall within the predetermined error range or approximately 1:3. If the microcomputer 10 decides that an output signal of the crank angle sensor 18 is abnormal, then the cylinder identification is repeated.
In the example of the conventional art illustrated in FIG. 10 and FIG. 11, based on the count value on the cylinder identification counter, it has been determined whether or not an output signal of a crank angle sensor has been contaminated with noise according to the ratio of the cycle of the crank angle 10.degree. CA between particular angle signals B75.degree. CA and B65.degree. CA to the cycle of the crank angle 30.degree. CA between particular angle signals B65 and B35. In other words, the ratio of the cycles therebetween is 10:30=1:3, and it has been determined that a particular angle signal is free of noise if the cycle ratio stays around 1:3, while it has been determined that the signal involves noise if it substantially deviates from 1:3.
Thus, in this case, as shown in FIG. 11A and FIG. 11B, the operational processing such as ignition and fuel injection of the internal combustion engine is performed by the interrupts of the particular angle signals B75, B5 and B115. Therefore, in the past, if noise enters during the period between the previous cylinder crank angle B35.degree. CA and the present cylinder crank angle B75.degree. CA, the entry of noise is determined after the present cylinder crank angle B75.degree. CA, so that by the time the noise is determined, the operational processing will have already been completed at the wrong previous cylinder crank angle B5.degree. CA and the present cylinder crank angles B115.degree. CA and B75.degree. CA. Hence, even if the entry of noise is determined, the previous operational processing will have already been finished, failing to effectively inhibit erroneous operations caused by noise.
Further, the noise determination is effected also at the time of starting up an engine when a sudden change is anticipated in the rotational speed of the engine or the rotational speed of a crankshaft. Hence, there has been a possibility of an erroneous determination of noise due to a sudden change in the output signal cycle of a crank angle sensor.